﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/Master/Admin.Master" AutoEventWireup="true"
    CodeBehind="WebTemplateList.aspx.cs" Inherits="Besture.UI.WebTemplateList" %>

<asp:Content ID="Content1" ContentPlaceHolderID="Head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Content" runat="server">
    <div class="mainbox">
        <!--顶部操作按钮开始-->
        <div class="operateBar">
            <ul>
                <li><a href="javascript:grid.SelectRows();" class="operate-all"><s class="icon-gou-red">
                </s>全选</a></li>
                <li><a href="javascript:grid.UnselectRows();" class="operate-cancel"><s class="icon-cancel-yellow">
                </s>取消</a></li>
                <li>
                    <asp:LinkButton ID="lbAllDelete" runat="server" OnClientClick="return confirm('删除后无法恢复，确定删除选中项吗?');"
                        class="operate-delete" OnClick="BtnDelClick"><s class="icon-delete"></s>删除</asp:LinkButton>
                </li>
                <li>
                    <asp:LinkButton ID="lbAdd" runat="server" class="operate-add" OnClick="BtnAddClick"><s class="icon-add-green"></s>添加</asp:LinkButton>
                </li>
            </ul>
        </div>
        <!--顶部操作按钮结束-->
        <cms:ASPxGridView ID="grid" ClientInstanceName="grid" runat="server" Width="99%"
            AutoGenerateColumns="False" KeyFieldName="ID" OnCustomCallback="GridCustomCallback"
            OnRowDeleting="GridRowDeleting">
            <Columns>
                <cms:GridViewCommandColumn ShowSelectCheckbox="true" VisibleIndex="0" Width="50px"
                    FixedStyle="Left">
                    <HeaderTemplate>
                        <input type="checkbox" onclick="grid.SelectAllRowsOnPage(this.checked);" title="全选/全不选"
                            id="chkAll" runat="server" />
                    </HeaderTemplate>
                    <HeaderStyle HorizontalAlign="Center" />
                </cms:GridViewCommandColumn>
                <cms:GridViewDataTextColumn VisibleIndex="1" Caption="操作" Width="80px" HeaderStyle-HorizontalAlign="Center"
                    CellStyle-HorizontalAlign="Center"  FixedStyle="Left">
                    <DataItemTemplate>
                         <div class="operateBox">
                        <a class="btn-text-edit" href="WebTemplateSet.aspx?id=<%# Eval("ID") %>" title="编辑">
                        </a>&nbsp;&nbsp; <a class="btn-text-del" onclick="window.setTimeout(function(){aspxGVDeleteRow('ctl00_Content_grid',<%# Container.ItemIndex %>);},0)"
                            title="删除"></a>
                            </div>
                    </DataItemTemplate>
                </cms:GridViewDataTextColumn>

                <cms:GridViewDataTextColumn Caption="模版名称" VisibleIndex="3" Width="" HeaderStyle-HorizontalAlign="Center"
                    CellStyle-HorizontalAlign="Center" FieldName="Name">
                    <Settings AutoFilterCondition="Contains"></Settings>
                </cms:GridViewDataTextColumn>
                <cms:GridViewDataTextColumn Caption="模版文件名" VisibleIndex="4" Width="" HeaderStyle-HorizontalAlign="Center"
                    CellStyle-HorizontalAlign="Center" FieldName="TemplateName">
                    <Settings AutoFilterCondition="Contains"></Settings>
                </cms:GridViewDataTextColumn>
            </Columns>
        </cms:ASPxGridView>
    </div>
</asp:Content>
